<!DOCTYPE html>

<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- 上述3个meta标签*必须*放在最前面，任何其他内容都*必须*跟随其后！ -->
    <meta name="description" content="">
    <meta name="author" content="">
    <link rel="icon" href="/static/index/img/small-logo.jpg">
    <title>漫画世界，为漫画而生</title>

    <!-- Bootstrap core CSS -->
    {css href="/static/index/css/bootstrap.min.css" }
    {css href="/static/index/css/navbar-fixed-top.css" }
    {css href="/static/index/css/zjh.css" }
    {css href="/static/index/css/toastr.min.css"}
    {js href="/static/index/js/jquery.min.js" }
    {js href="/static/index/js/bootstrap.min.js" }
    {js href="/static/index/js/toastr.min.js"}

    <style type="text/css" abt="234"></style>
</head>

<html lang="zh-CN">

<body>

<!-- Fixed navbar -->
<nav class="navbar navbar-default navbar-fixed-top">
    <div class="container">
        <div class="navbar-header">
            <img class="active" src="/static/index/img/logo.jpg" width="150">
        </div>
        <div id="navbar" class="navbar-collapse collapse">
            <ul class="nav navbar-nav">
                <li class="active">
                    <a href="{:url('/home/index/index')}">首页</a>
                </li>
                <li>
                    <a href="{:url('/home/index/gengxin')}">更新</a>
                </li>
                <li>
                    <a href="{:url('/home/index/paihang')}">排行</a>
                </li>
                <li>
                    <!-- 搜索框 -->
                    <div class="input-group" style="width: 300px;margin-top:8px">
                        <input type="text" class="form-control" placeholder="请输入搜索内容">
                        <span class="input-group-btn">
                                <button class="btn btn-danger" type="button">Go!</button>
                            </span>
                    </div>
                </li>
            </ul>
            <ul class="nav navbar-nav navbar-right">
                <li>
                    <a href="{:url('/home/index/vip')}" class="glyphicon glyphicon-queen">VIP</a>
                </li>
                <li>
                    <a href="{:url('/home/index/user')}" class="glyphicon glyphicon-star">书架</a>
                </li>
                {if condition="$ses['vip'] eq 2"}
                <li  class="active ">
                    <img src="/static/index/img/vip_logo_2.png" width="48">
                </li>
                <li class="active ">
                    <a href="{:url('/home/index/user')}" class="glyphicon glyphicon-user">个人中心</a>
                </li>
                
                {else /}
                <li class="active ">
                    <a href="{:url('/home/index/user')}" class="glyphicon glyphicon-user">个人中心</a>
                </li>
                {/if}
                <li  class="active ">
                    <a href="{:url('/home/login/tuichu')}">退出</a>
                </li>
            </ul>
        </div>
        <!--/.nav-collapse -->
    </div>
</nav>
<div style="height: 50px"></div>
<div class="container" style="margin-top:50px">
    <div class="row">
        <!--左侧-->
        <div class="col-md-2 user-left">
            {if condition = "$data['icon']"}
            <img src="/uploads/{$data.icon}" width="100" height="100" class="img-circle">
            {else/}
            <img src="/static/index/img/touxiang.jpg" width="100" height="100" class="img-circle">
            {/if}
            <hr>
            {if condition = "$data['name']"} <p>{$data.name}</p>
            {else/} <p>未设置用户名</p>
            {/if}
            <hr>
            <br>
            <br>
            <ul class="list-unstyled">
                <li><span class="glyphicon glyphicon-list-alt"></span>&nbsp;&nbsp; <a href="{:url('/home/index/user')}"> 我的书架</a></li>
                <br>
                <li><span class="glyphicon glyphicon-queen"></span>&nbsp;&nbsp; <a href="{:url('/home/index/user_vip')}"> VIP会员</a></li>
                <br>
                <li><span class="glyphicon glyphicon-erase"></span>&nbsp;&nbsp; <a href="{:url('/home/index/xiugai')}"> 修改资料</a></li>
                <br>
                <li><span class="glyphicon glyphicon-level-up"></span>&nbsp;&nbsp; <a href="{:url('/home/index/shangchuan')}"> 上传作品</a></li>
                <br>
            </ul>
        </div>
        {block name="user-main"}
        <!--右侧-->
        <div class="col-md-10 user-right">
            <span style="font-size: 20px">我的书架</span>
            <hr>
            {volist name='book_data' id='v'}
            <div>
                <a href=""><img src="/uploads/{$v['pic']}" width="150" height="180" ></a>
                <br>
                标题:{$v.name}
                <br>
                简介:{$v.detail|mb_substr=0,10}
                <br>
                <button class="glyphicon glyphicon-remove del_btn" data-id={$v.id} style="color:red;"></button>
            </div>
            {/volist}
        </div>

        <script>
            $(function(){

                //    弹框参数
                toastr.options = {
                    closeButton: true,
                    progressBar: true,
                    timeOut: "2000",
                    positionClass: "toast-top-right"
                };
                //  触发删除按钮
                $('.del_btn').click(function(){
                    var ac_id = $(this).attr('data-id');
                    if(confirm('确定删除？')){
                        var obj = $(this).parent('div');
                        del_book(ac_id,obj);
                    }
                })
            });
            function del_book(id,obj){
                $.ajax({
                    type:'delete',
                    url:'/bookmarkers/'+id+'.html',
                    dataType : 'json',
                    success:function(data){
                        if(data.status){
                            toastr.success(data.info);
                            obj.remove();
                        }else{
                            toastr.error(data.info, 'WARING!!!!!!:');
                        }
                    },
                    error:function(data){
                        alert('AJAX操作失败');
                    }
                })
            }

        </script>


        {/block}
    </div>
<div style="height: 200px">

</div>
<!-- 右侧悬浮框  -->
<div>
    <ul class="nav nav-pills nav-stacked xuanfu">
        <li>
            <a href=" ">原创</a>
        </li>
        <li>
            <a href=" ">热血</a>
        </li>
        <li>
            <a href=" ">科幻</a>
        </li>
        <li>
            <a href=" ">战争</a>
        </li>
        <li>
            <a href=" ">恋爱</a>
        </li>
        <li>
            <a href=" ">悬疑</a>
        </li>
        <li>
            <a href=" ">恐怖</a>
        </li>
        <li>
            <a href=" ">搞笑</a>
        </li>
        <li>
            <a href=" ">历史</a>
        </li>
        <li>
            <span class="glyphicon glyphicon-arrow-up top_btn" style="margin-left: 15px"></span>
        </li>
    </ul>
</div>

<!--友情连接-->
<div class="jumbotron"  style="margin-top:30px;">
    <div class="container">
        <p class="glyphicon glyphicon-link">友情链接</p>
        <hr>
        <div class="row">
            <div class="col-md-4">
                <ul class="list-unstyled">
                    <li>========</li>
                    <li>========</li>
                    <li>========</li>
                    <li>========</li>
                </ul>
            </div>
            <div class="col-md-4">
                <ul class="list-unstyled">
                    <li>========</li>
                    <li>========</li>
                    <li>========</li>
                    <li>========</li>
                </ul>
            </div>
            <div class="col-md-4">
                <ul class="list-unstyled">
                    <li>========</li>
                    <li>========</li>
                    <li>========</li>
                    <li>========</li>
                </ul>
            </div>
        </div>
        <hr>
        <img src="/static/index/img/logo.jpg" width="200">
        <br>
        <a href="">关于我们</a>&nbsp;&nbsp;&nbsp;丨
        <a href="">商务合作</a>&nbsp;&nbsp;&nbsp;丨
        <a href="">建议与投诉</a>&nbsp;&nbsp;&nbsp;丨
        <a href="">版权声明</a>
        <br>
        Copyright (C) 2010-2020 www.xxx.com 漫画世界 All rights reserved
        <br>
        [网络文化经营许可证：浙网文[xxxx]xxxx-xxx号]    [网站备案：浙ICP备xxxxxxxx号-x]
    </div>
</div>
    <script>
        $(function(){
            $(function(){
                $(".top_btn").click(function() {
                    $("html,body").animate({scrollTop:0}, 500);
                });
            })
        })

    </script>

</body>

</html>
